﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ShowReports.aspx.cs" Inherits="ShowReports" %>

<%@ Register Assembly="DevExpress.Web.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxCallbackPanel" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxPager" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxEditors.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxDataView" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.2.Linq, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Data.Linq" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxPanel" TagPrefix="dx" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
    <link href="Content/web20110913.css" rel="stylesheet" type="text/css" charset="gb2312" />
    <script type="text/javascript">
        //城区选择
        //        function OnDisChanged(cmbdis) {
        //            cmbapp.PerformCallback(cmbdis.GetValue().toString());
        //        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <dx:ASPxCallbackPanel ID="CBPanel" ClientInstanceName="QueryPanel" runat="server"
            OnCallback="CBPanel_Callback" Width="1250px">
            <PanelCollection>
                <dx:PanelContent>
                    <table border="0px" cellspacing="0" cellpadding="0" width="1200px" class="table11">
                        <tr>
                            <td align="right">
                                单位：
                            </td>
                            <td>
                                <dx:ASPxComboBox ID="cmbDis" runat="server" DataSourceID="SDSDis" ValueType="System.String"
                                    TextField="Community_Name" ValueField="Community_ID" DropDownStyle="DropDown"
                                    CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" CssPostfix="Office2010Blue"
                                    Spacing="0" SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" Font-Size="9pt">
                                    <ItemStyle HorizontalAlign="Left" />
                                    <LoadingPanelImage Url="~/App_Themes/Office2010Blue/Editors/Loading.gif">
                                    </LoadingPanelImage>
                                    <LoadingPanelStyle ImageSpacing="5px">
                                    </LoadingPanelStyle>
                                    <ButtonStyle Width="13px">
                                    </ButtonStyle>
                                </dx:ASPxComboBox>
                                <asp:SqlDataSource ID="SDSDis" runat="server" ConnectionString="<%$ ConnectionStrings:CMSConnectionString %>"
                                    SelectCommand="SELECT [Community_ID], [Community_Name] FROM [Community] WHERE ([Parent_ID] = @Parent_ID)">
                                    <SelectParameters>
                                        <asp:Parameter DefaultValue="0" Name="Parent_ID" Type="String" />
                                    </SelectParameters>
                                </asp:SqlDataSource>
                            </td>
                            <td align="right">
                                项目类型：
                            </td>
                            <td>
                                <dx:ASPxComboBox ID="cmbType" runat="server" DataSourceID="SDSProType" TextField="Type_Name"
                                    ValueField="Type_ID" DropDownStyle="DropDown" CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css"
                                    CssPostfix="Office2010Blue" Spacing="0" SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css"
                                    Font-Size="9pt">
                                    <LoadingPanelImage Url="~/App_Themes/Office2010Blue/Editors/Loading.gif">
                                    </LoadingPanelImage>
                                    <LoadingPanelStyle ImageSpacing="5px">
                                    </LoadingPanelStyle>
                                    <ButtonStyle Width="13px">
                                    </ButtonStyle>
                                </dx:ASPxComboBox>
                                <asp:SqlDataSource ID="SDSProType" runat="server" ConnectionString="<%$ ConnectionStrings:CMSConnectionString %>"
                                    SelectCommand="SELECT * FROM [TypeInfo]"></asp:SqlDataSource>
                            </td>
                            <td align="right">
                                批文号：
                            </td>
                            <td>
                                <dx:ASPxComboBox ID="cmbAppNum" ClientInstanceName="cmbapp" runat="server" TextField="Approal_ID"
                                    DataSourceID="SDSAppNumDis" ValueField="Approal_ID" DropDownStyle="DropDown"
                                    CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" CssPostfix="Office2010Blue"
                                    Spacing="0" SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" Font-Size="9pt">
                                    <ItemStyle HorizontalAlign="Left" />
                                    <LoadingPanelImage Url="~/App_Themes/Office2010Blue/Editors/Loading.gif">
                                    </LoadingPanelImage>
                                    <LoadingPanelStyle ImageSpacing="5px">
                                    </LoadingPanelStyle>
                                    <ButtonStyle Width="13px">
                                    </ButtonStyle>
                                </dx:ASPxComboBox>
                                <%-- <asp:SqlDataSource ID="SDSAppNum" runat="server" ConnectionString="<%$ ConnectionStrings:ManagerConnectionString %>"
                                    SelectCommand="SELECT [Approal_ID], [ComminityID] FROM [Approal] WHERE ([ComminityID] = @ComminityID)">
                                    <SelectParameters>
                                        <asp:ControlParameter ControlID="cmbDis" Name="ComminityID" PropertyName="Value"
                                            Type="String" />
                                    </SelectParameters>
                                </asp:SqlDataSource>--%>
                                <asp:SqlDataSource ID="SDSAppNumDis" runat="server" ConnectionString="<%$ ConnectionStrings:ManagerConnectionString %>"
                                    SelectCommand="select distinct Approal_ID from Approal"></asp:SqlDataSource>
                            </td>
                            <td align="right">
                                年度：
                            </td>
                            <td>
                                <asp:TextBox ID="txtDate" runat="server" Height="20px"></asp:TextBox>
                            </td>
                            <td align="right">
                                <dx:ASPxButton ID="btnQuery" runat="server" Text="查询" AutoPostBack="False" UseSubmitBehavior="False"
                                    CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" CssPostfix="Office2010Blue"
                                    SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css" Font-Bold="False">
                                    <ClientSideEvents Click="function(s,e){QueryPanel.PerformCallback();}" />
                                </dx:ASPxButton>
                            </td>
                            <td align="right">
                                <dx:ASPxButton ID="btnExport" runat="server" Text="导出到Excel" OnClick="btnExport_Click"
                                    CssFilePath="~/App_Themes/Office2010Blue/{0}/styles.css" CssPostfix="Office2010Blue"
                                    SpriteCssFilePath="~/App_Themes/Office2010Blue/{0}/sprite.css">
                                </dx:ASPxButton>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="10" align="right">
                                <asp:HyperLink ID="HyperLink1" runat="server" Font-Size="Medium" NavigateUrl="~/ShowProject.aspx">返回项目管理>>></asp:HyperLink>
                            </td>
                        </tr>
                    </table>
                    <div class="div11">
                        <asp:GridView ID="gvShowReports" runat="server" OnRowDataBound="gvShowReports_RowDataBound"
                            EnableModelValidation="True" OnRowCreated="gvShowReports_RowCreated" AutoGenerateColumns="False"
                            Width="100%" Font-Size="12pt">
                            <Columns>
                                <asp:BoundField DataField="Type_Name" ItemStyle-Width="150px" HeaderText="Type_Name"
                                    SortExpression="Type_Name">
                                    <ItemStyle Width="100px" HorizontalAlign="Center"></ItemStyle>
                                </asp:BoundField>
                                <asp:BoundField DataField="Project_Name" HeaderText="Project_Name" SortExpression="Project_Name">
                                    <ItemStyle Width="100px" HorizontalAlign="Center" />
                                </asp:BoundField>
                                <asp:BoundField DataField="Project_Development" ItemStyle-Width="100px" HeaderText="Project_Development"
                                    SortExpression="Project_Development">
                                    <ItemStyle Width="100px" HorizontalAlign="Center"></ItemStyle>
                                </asp:BoundField>
                                <asp:TemplateField HeaderText="Project_BasicInfo" SortExpression="Project_BasicInfo">
                                    <ItemTemplate>
                                        <asp:Label ID="Label1" runat="server" Text='<%#GetAllBasicInfo(Eval("Project_BasicInfo").ToString(),Eval("Project_Address").ToString(),Eval("Project_Scope").ToString(),Eval("ServeObiect").ToString(),Eval("ServerPersontime").ToString(),Eval("ContactWay").ToString(),Eval("other").ToString()) %>'></asp:Label>
                                    </ItemTemplate>
                                    <ItemStyle HorizontalAlign="Left" Width="150px" />
                                </asp:TemplateField>
                                <asp:BoundField DataField="Project_CitySubsidy" HeaderText="Project_CitySubsidy"
                                    SortExpression="Project_CitySubsidy">
                                    <ItemStyle Width="80px" HorizontalAlign="Center" />
                                </asp:BoundField>
                                <asp:BoundField DataField="Project_DistrictFund" ItemStyle-Width="100px" HeaderText="Project_DistrictFund"
                                    SortExpression="Project_DistrictFund">
                                    <ItemStyle Width="80px" HorizontalAlign="Center"></ItemStyle>
                                </asp:BoundField>
                                <asp:BoundField DataField="Project_FundsTotal" HeaderText="Project_FundsTotal" SortExpression="Project_FundsTotal">
                                    <ItemStyle Width="80px" HorizontalAlign="Center" />
                                </asp:BoundField>
                                <asp:BoundField DataField="Project_Performance" ItemStyle-Width="100px" HeaderText="Project_Performance"
                                    SortExpression="Project_Performance">
                                    <ItemStyle Width="150px"></ItemStyle>
                                </asp:BoundField>
                            </Columns>
                        </asp:GridView>
                    </div>
                </dx:PanelContent>
            </PanelCollection>
        </dx:ASPxCallbackPanel>
    </div>
    </form>
</body>
</html>
